package org.dromara.app.cssUtils;

/**
 * redis Key表头
 */
public class RedisServiceUtils {

    private final static String AppUser = "AppUser:";
    private final static String loginToken = "loginToken";
    private final static String SendCode = "SendCode:";
    private final static String ZAIXIANUSER = "zaixianuser:";
    //待接单订单一直没有接单到达开始时间取消订单
    private final static String DAIJIEDANTUIKUAN = "dai_jie_dan_tui_kuan";
    private final static String YUEJULIKELIKE = "yue_ju_like_list";
    private final static String YUEJULIKENUMBER = "yue_ju_like_number";

    private final static String YUEDANWANCHENG = "yue_dan_wancheng";

    private final static String YUEDANORDER = "yuedanorder";

    //已满15分钟退款，扣除比例
    private final static String TUIKUANBILI = "tui_kuan_bi_li";


    /**
     * 用户信息
     *
     * @param id
     * @return
     */
    public static String userInfo(Long id) {
        return AppUser + id;
    }

    /**
     * 登录APP信令
     *
     * @param token
     * @return
     */
    public static String loginToken(String token) {
        return loginToken +":"+ token;
    }

    /**
     * 短信验证码
     *
     * @param phone
     * @return
     */
    public static String SendCode(String phone) {
        return SendCode + phone;
    }

    public static String getZaixianuser(Long userId) {
        return ZAIXIANUSER + userId;
    }

    public static String getDaijiedantuikuan(Long orderId) {
        return DAIJIEDANTUIKUAN + ":" + orderId;
    }

    public static String getDaijiedantuikuanTitle() {
        return DAIJIEDANTUIKUAN;
    }
    public static String loginTokenTitle() {
        return loginToken;
    }
    //点赞列表用户
    public static String getYueJuLikeuser(Long yuejuId) {
        return YUEJULIKELIKE+":"+yuejuId;
    }
    //点赞总数
    public static String getYueJuAllZanNumber(Long yuejuId) {
        return YUEJULIKENUMBER+":"+yuejuId;
    }

    /**
     * 在线用户用户资料
     * @return
     */
    public static String getOnlineUsers() {
        return "online-users";
    }

    /**
     * 用户资料
     */
    public static String getUserInfo() {
        return "userInfo";
    }

    /**
     * 在线用户过期配置
     */
    public static String getOnlineUsersTime() {
        return "online-users-time";
    }

    public static String getLianXiLogin() {
        return "lianxi-login";
    }

    public static String getTuikuanbili() {
        return TUIKUANBILI;
    }


    public static String getDaRenWanCheng(Long id){
        return YUEDANWANCHENG+":"+id;
    }

    /**
     * 约单结束倒计时 监控
     * @return
     */
    public static Object getYueDanOrder() {
        return "yue_dan_order";
    }
}
